#pragma once
namespace wjb
{
	template<class K>
	class unordered_set
	{
		struct SetKeyOfT
		{
			const K& operator()(const K& key)
			{
				return key;
			}
		};

	public:
		typedef typename hash_bucket::hashTable<K, K, SetKeyOfT>::const_Iterator iterator;
		typedef typename hash_bucket::hashTable<K, K, SetKeyOfT>::const_Iterator const_iterator;

		iterator begin()const
		{
			return _ht.begin();
		}

		iterator end()const
		{
			return _ht.end();
		}


		pair<iterator,bool> insert(const K& key)
		{
			pair<typename hash_bucket::hashTable<K, K, SetKeyOfT>::Iterator, bool> tmp = _ht.Insert(key);
			return pair<iterator,bool>(tmp.first,tmp.second);
		}

		bool erase(const K& key)
		{
			return _ht.Erase(key);
		}



	private:
		hash_bucket::hashTable<K, K, SetKeyOfT> _ht;
	};
}
